Skip to main content
POST
Upsert a mirror source for the authenticated user. Toggling `enabled` notifies the mirror process over NATS so it can start/stop the per-user task without a restart.

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Body

application/json
provider
string
required

One of: lastfm, listenbrainz, tealfm

enabled
boolean

Enable or disable mirroring for this provider.

externalUsername
string

External username (Last.fm / ListenBrainz). Required when enabling those providers. Ignored for Teal.fm.

apiKey
string

API key / token to be encrypted at rest. Omit to leave the existing key unchanged. Pass an empty string to clear it.

Response

OK

provider
string
required

One of: lastfm, listenbrainz, tealfm

enabled
boolean
required

Whether scrobbles from this source are being mirrored into Rocksky.

hasCredentials
boolean
required

True when an API key is stored. Last.fm/ListenBrainz only; always false for Teal.fm.

externalUsername
string

Username on the external service (Last.fm / ListenBrainz). Null for Teal.fm.

lastPolledAt
string<date-time>

The last time the mirror process successfully polled this source.

lastScrobbleSeenAt
string<date-time>

Watermark — scrobbles from the external service older than this are skipped.